Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect code sample of update method in readme.md #720

Closed

Conversation

ndjndj
Copy link
Contributor

@ndjndj ndjndj commented Feb 20, 2024

Hello, thank you for maintenance of this gem.

Probably related to issue #657.

I found what incorrect code sample of update method in readme.md.

.update method does not accept conditions as arguments.

def update(hash_key, range_key_value = nil, attrs)

Therefore, the following code as shown in the sample will fail.

Address.update(id, { city: 'Chicago' }, if: { deliverable: true })

So I removed this code sample.

thank you!

Copy link

codecov bot commented Feb 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (a5b7640) 90.89% compared to head (d9dd786) 90.89%.
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #720   +/-   ##
=======================================
  Coverage   90.89%   90.89%           
=======================================
  Files          71       71           
  Lines        3414     3414           
=======================================
  Hits         3103     3103           
  Misses        311      311           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@andrykonchin
Copy link
Member

Thank you! Could you please rebase the branch on master?

@ndjndj
Copy link
Contributor Author

ndjndj commented Feb 21, 2024

I’m sorry. Is this correct?

@andrykonchin
Copy link
Member

andrykonchin commented Feb 21, 2024

Could you please squash all commits into one? I would do it myself and push with force into your branch but it seems it's not permitted.

remove code sample that not exist as specifications in update method.

remove code sample that not exist as specifications in update method.

remove code sample that not exist as specifications in update method.

remove code sample that not exist as specifications in update method.
…/dynamoid into update-sample-incorrect-in-readme
@ndjndj
Copy link
Contributor Author

ndjndj commented Feb 21, 2024

I'm sorry but I accidentaly broke branch.
I apologize for the repeated trouble.
I will create a new branch and submit a new pull request.

@ndjndj ndjndj closed this Feb 21, 2024
@ndjndj ndjndj deleted the update-sample-incorrect-in-readme branch February 21, 2024 12:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants